Integrand size = 19, antiderivative size = 27 \[ \int \csc (e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx=-\frac {(a+b) \text {arctanh}(\cos (e+f x))}{f}+\frac {b \sec (e+f x)}{f} \]
[Out]
Time = 0.04 (sec) , antiderivative size = 27, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.158, Rules used = {4218, 464, 212} \[ \int \csc (e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx=\frac {b \sec (e+f x)}{f}-\frac {(a+b) \text {arctanh}(\cos (e+f x))}{f} \]
[In]
[Out]
Rule 212
Rule 464
Rule 4218
Rubi steps \begin{align*} \text {integral}& = -\frac {\text {Subst}\left (\int \frac {b+a x^2}{x^2 \left (1-x^2\right )} \, dx,x,\cos (e+f x)\right )}{f} \\ & = \frac {b \sec (e+f x)}{f}-\frac {(a+b) \text {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,\cos (e+f x)\right )}{f} \\ & = -\frac {(a+b) \text {arctanh}(\cos (e+f x))}{f}+\frac {b \sec (e+f x)}{f} \\ \end{align*}
Leaf count is larger than twice the leaf count of optimal. \(84\) vs. \(2(27)=54\).
Time = 0.07 (sec) , antiderivative size = 84, normalized size of antiderivative = 3.11 \[ \int \csc (e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx=-\frac {a \log \left (\cos \left (\frac {e}{2}+\frac {f x}{2}\right )\right )}{f}-\frac {b \log \left (\cos \left (\frac {1}{2} (e+f x)\right )\right )}{f}+\frac {a \log \left (\sin \left (\frac {e}{2}+\frac {f x}{2}\right )\right )}{f}+\frac {b \log \left (\sin \left (\frac {1}{2} (e+f x)\right )\right )}{f}+\frac {b \sec (e+f x)}{f} \]
[In]
[Out]
Time = 0.12 (sec) , antiderivative size = 40, normalized size of antiderivative = 1.48
method | result | size |
norman | \(-\frac {2 b}{f \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}-1\right )}+\frac {\left (a +b \right ) \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{f}\) | \(40\) |
parallelrisch | \(\frac {\cos \left (f x +e \right ) \left (a +b \right ) \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right )+b \left (1+\cos \left (f x +e \right )\right )}{f \cos \left (f x +e \right )}\) | \(44\) |
derivativedivides | \(\frac {a \ln \left (\csc \left (f x +e \right )-\cot \left (f x +e \right )\right )+b \left (\frac {1}{\cos \left (f x +e \right )}+\ln \left (\csc \left (f x +e \right )-\cot \left (f x +e \right )\right )\right )}{f}\) | \(51\) |
default | \(\frac {a \ln \left (\csc \left (f x +e \right )-\cot \left (f x +e \right )\right )+b \left (\frac {1}{\cos \left (f x +e \right )}+\ln \left (\csc \left (f x +e \right )-\cot \left (f x +e \right )\right )\right )}{f}\) | \(51\) |
risch | \(\frac {2 b \,{\mathrm e}^{i \left (f x +e \right )}}{f \left ({\mathrm e}^{2 i \left (f x +e \right )}+1\right )}+\frac {\ln \left ({\mathrm e}^{i \left (f x +e \right )}-1\right ) a}{f}+\frac {\ln \left ({\mathrm e}^{i \left (f x +e \right )}-1\right ) b}{f}-\frac {\ln \left ({\mathrm e}^{i \left (f x +e \right )}+1\right ) a}{f}-\frac {\ln \left ({\mathrm e}^{i \left (f x +e \right )}+1\right ) b}{f}\) | \(100\) |
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 60 vs. \(2 (27) = 54\).
Time = 0.25 (sec) , antiderivative size = 60, normalized size of antiderivative = 2.22 \[ \int \csc (e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx=-\frac {{\left (a + b\right )} \cos \left (f x + e\right ) \log \left (\frac {1}{2} \, \cos \left (f x + e\right ) + \frac {1}{2}\right ) - {\left (a + b\right )} \cos \left (f x + e\right ) \log \left (-\frac {1}{2} \, \cos \left (f x + e\right ) + \frac {1}{2}\right ) - 2 \, b}{2 \, f \cos \left (f x + e\right )} \]
[In]
[Out]
\[ \int \csc (e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx=\int \left (a + b \sec ^{2}{\left (e + f x \right )}\right ) \csc {\left (e + f x \right )}\, dx \]
[In]
[Out]
none
Time = 0.19 (sec) , antiderivative size = 44, normalized size of antiderivative = 1.63 \[ \int \csc (e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx=-\frac {{\left (a + b\right )} \log \left (\cos \left (f x + e\right ) + 1\right ) - {\left (a + b\right )} \log \left (\cos \left (f x + e\right ) - 1\right ) - \frac {2 \, b}{\cos \left (f x + e\right )}}{2 \, f} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 60 vs. \(2 (27) = 54\).
Time = 0.28 (sec) , antiderivative size = 60, normalized size of antiderivative = 2.22 \[ \int \csc (e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx=\frac {{\left (a + b\right )} \log \left (\frac {{\left | -\cos \left (f x + e\right ) + 1 \right |}}{{\left | \cos \left (f x + e\right ) + 1 \right |}}\right ) + \frac {4 \, b}{\frac {\cos \left (f x + e\right ) - 1}{\cos \left (f x + e\right ) + 1} + 1}}{2 \, f} \]
[In]
[Out]
Time = 0.10 (sec) , antiderivative size = 29, normalized size of antiderivative = 1.07 \[ \int \csc (e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx=\frac {b}{f\,\cos \left (e+f\,x\right )}-\frac {\mathrm {atanh}\left (\cos \left (e+f\,x\right )\right )\,\left (a+b\right )}{f} \]
[In]
[Out]